package com.xqls.dal.dao.mybatis;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import com.xqls.dal.dao.FluggasDischargeRealdataDao;
import com.xqls.dal.model.FluggasDischargeRealdata;
import com.xqls.dal.model.FluggasDischargeRealdataExample;
import com.xqls.dal.service.FluggasDischargeRealdataMapper;

@Repository
public class FluggasDischargeRealdataDaoImpl implements FluggasDischargeRealdataDao {

	@Autowired FluggasDischargeRealdataMapper mapper;
	
	@Override
	public boolean insertRealdata(FluggasDischargeRealdata record) {
		boolean isSuccess=false;
		if(this.mapper.insert(record)>0)
		{
			isSuccess=true;
		}
		return isSuccess;
	}

	@Override
	public boolean updateRealdata(FluggasDischargeRealdata record) {
		boolean isSuccess=false;
		if(this.mapper.updateByPrimaryKeySelective(record)>0)
		{
			isSuccess=true;
		}
		return isSuccess;
	}

	@Override
	public int getRealdataCountByExample(FluggasDischargeRealdataExample example) {
		return this.mapper.countByExample(example);
	}
	
	@Override
	public List<Map<String, Object>> getListAll() {
		return this.mapper.getListAll();
	}

	@Override
	public List<Map<String, Object>> selectByMap(Map<String, Object> map) {
		return mapper.selectByMap(map);
	}

	@Override
	public FluggasDischargeRealdata selectBydeviceNo(String deviceNo) {
		return mapper.selectBydeviceNo(deviceNo);
	}

	@Override
	public List<FluggasDischargeRealdata> selectFluggas() {
		return mapper.selectFluggas();
	}

	@Override
	public List<FluggasDischargeRealdata> getListByExample(FluggasDischargeRealdataExample example) {
		return this.mapper.selectByExample(example);
	}
}
